Optimal. Leaf size=114 \[ -\frac {\left (a^2-8 a b+4 b^2\right ) \tanh (c+d x)}{4 d}+\frac {1}{8} x \left (3 a^2-24 a b+8 b^2\right )+\frac {a^2 \sinh ^4(c+d x) \tanh (c+d x)}{4 d}-\frac {a (a-8 b) \sinh (c+d x) \cosh (c+d x)}{8 d}-\frac {b^2 \tanh ^3(c+d x)}{3 d} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.14, antiderivative size = 114, normalized size of antiderivative = 1.00, number of steps used = 6, number of rules used = 5, integrand size = 23, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.217, Rules used = {4132, 463, 455, 1153, 206} \[ -\frac {\left (a^2-8 a b+4 b^2\right ) \tanh (c+d x)}{4 d}+\frac {1}{8} x \left (3 a^2-24 a b+8 b^2\right )+\frac {a^2 \sinh ^4(c+d x) \tanh (c+d x)}{4 d}-\frac {a (a-8 b) \sinh (c+d x) \cosh (c+d x)}{8 d}-\frac {b^2 \tanh ^3(c+d x)}{3 d} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 206
Rule 455
Rule 463
Rule 1153
Rule 4132
Rubi steps
\begin {align*} \int \left (a+b \text {sech}^2(c+d x)\right )^2 \sinh ^4(c+d x) \, dx &=\frac {\operatorname {Subst}\left (\int \frac {x^4 \left (a+b-b x^2\right )^2}{\left (1-x^2\right )^3} \, dx,x,\tanh (c+d x)\right )}{d}\\ &=\frac {a^2 \sinh ^4(c+d x) \tanh (c+d x)}{4 d}-\frac {\operatorname {Subst}\left (\int \frac {x^4 \left (5 a^2-4 (a+b)^2+4 b^2 x^2\right )}{\left (1-x^2\right )^2} \, dx,x,\tanh (c+d x)\right )}{4 d}\\ &=-\frac {a (a-8 b) \cosh (c+d x) \sinh (c+d x)}{8 d}+\frac {a^2 \sinh ^4(c+d x) \tanh (c+d x)}{4 d}-\frac {\operatorname {Subst}\left (\int \frac {-a (a-8 b)-2 a (a-8 b) x^2-8 b^2 x^4}{1-x^2} \, dx,x,\tanh (c+d x)\right )}{8 d}\\ &=-\frac {a (a-8 b) \cosh (c+d x) \sinh (c+d x)}{8 d}+\frac {a^2 \sinh ^4(c+d x) \tanh (c+d x)}{4 d}-\frac {\operatorname {Subst}\left (\int \left (2 \left (a^2-8 a b+4 b^2\right )+8 b^2 x^2+\frac {-3 a^2+24 a b-8 b^2}{1-x^2}\right ) \, dx,x,\tanh (c+d x)\right )}{8 d}\\ &=-\frac {a (a-8 b) \cosh (c+d x) \sinh (c+d x)}{8 d}-\frac {\left (a^2-8 a b+4 b^2\right ) \tanh (c+d x)}{4 d}+\frac {a^2 \sinh ^4(c+d x) \tanh (c+d x)}{4 d}-\frac {b^2 \tanh ^3(c+d x)}{3 d}+\frac {\left (3 a^2-24 a b+8 b^2\right ) \operatorname {Subst}\left (\int \frac {1}{1-x^2} \, dx,x,\tanh (c+d x)\right )}{8 d}\\ &=\frac {1}{8} \left (3 a^2-24 a b+8 b^2\right ) x-\frac {a (a-8 b) \cosh (c+d x) \sinh (c+d x)}{8 d}-\frac {\left (a^2-8 a b+4 b^2\right ) \tanh (c+d x)}{4 d}+\frac {a^2 \sinh ^4(c+d x) \tanh (c+d x)}{4 d}-\frac {b^2 \tanh ^3(c+d x)}{3 d}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A] time = 1.66, size = 153, normalized size = 1.34 \[ \frac {\text {sech}^3(c+d x) \left (a \cosh ^2(c+d x)+b\right )^2 \left (3 \cosh ^3(c+d x) \left (4 d x \left (3 a^2-24 a b+8 b^2\right )+a^2 \sinh (4 (c+d x))-8 a (a-2 b) \sinh (2 (c+d x))\right )+64 b (3 a-2 b) \text {sech}(c) \sinh (d x) \cosh ^2(c+d x)+32 b^2 \tanh (c) \cosh (c+d x)+32 b^2 \text {sech}(c) \sinh (d x)\right )}{24 d (a \cosh (2 (c+d x))+a+2 b)^2} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [B] time = 0.42, size = 342, normalized size = 3.00 \[ \frac {3 \, a^{2} \sinh \left (d x + c\right )^{7} + 3 \, {\left (21 \, a^{2} \cosh \left (d x + c\right )^{2} - 5 \, a^{2} + 16 \, a b\right )} \sinh \left (d x + c\right )^{5} + 8 \, {\left (3 \, {\left (3 \, a^{2} - 24 \, a b + 8 \, b^{2}\right )} d x - 48 \, a b + 32 \, b^{2}\right )} \cosh \left (d x + c\right )^{3} + 24 \, {\left (3 \, {\left (3 \, a^{2} - 24 \, a b + 8 \, b^{2}\right )} d x - 48 \, a b + 32 \, b^{2}\right )} \cosh \left (d x + c\right ) \sinh \left (d x + c\right )^{2} + {\left (105 \, a^{2} \cosh \left (d x + c\right )^{4} - 30 \, {\left (5 \, a^{2} - 16 \, a b\right )} \cosh \left (d x + c\right )^{2} - 63 \, a^{2} + 528 \, a b - 256 \, b^{2}\right )} \sinh \left (d x + c\right )^{3} + 24 \, {\left (3 \, {\left (3 \, a^{2} - 24 \, a b + 8 \, b^{2}\right )} d x - 48 \, a b + 32 \, b^{2}\right )} \cosh \left (d x + c\right ) + 3 \, {\left (7 \, a^{2} \cosh \left (d x + c\right )^{6} - 5 \, {\left (5 \, a^{2} - 16 \, a b\right )} \cosh \left (d x + c\right )^{4} - {\left (63 \, a^{2} - 528 \, a b + 256 \, b^{2}\right )} \cosh \left (d x + c\right )^{2} - 15 \, a^{2} + 160 \, a b\right )} \sinh \left (d x + c\right )}{192 \, {\left (d \cosh \left (d x + c\right )^{3} + 3 \, d \cosh \left (d x + c\right ) \sinh \left (d x + c\right )^{2} + 3 \, d \cosh \left (d x + c\right )\right )}} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [B] time = 0.18, size = 231, normalized size = 2.03 \[ \frac {3 \, a^{2} e^{\left (4 \, d x + 4 \, c\right )} - 24 \, a^{2} e^{\left (2 \, d x + 2 \, c\right )} + 48 \, a b e^{\left (2 \, d x + 2 \, c\right )} + 24 \, {\left (3 \, a^{2} - 24 \, a b + 8 \, b^{2}\right )} {\left (d x + c\right )} - 3 \, {\left (18 \, a^{2} e^{\left (4 \, d x + 4 \, c\right )} - 144 \, a b e^{\left (4 \, d x + 4 \, c\right )} + 48 \, b^{2} e^{\left (4 \, d x + 4 \, c\right )} - 8 \, a^{2} e^{\left (2 \, d x + 2 \, c\right )} + 16 \, a b e^{\left (2 \, d x + 2 \, c\right )} + a^{2}\right )} e^{\left (-4 \, d x - 4 \, c\right )} - \frac {256 \, {\left (3 \, a b e^{\left (4 \, d x + 4 \, c\right )} - 3 \, b^{2} e^{\left (4 \, d x + 4 \, c\right )} + 6 \, a b e^{\left (2 \, d x + 2 \, c\right )} - 3 \, b^{2} e^{\left (2 \, d x + 2 \, c\right )} + 3 \, a b - 2 \, b^{2}\right )}}{{\left (e^{\left (2 \, d x + 2 \, c\right )} + 1\right )}^{3}}}{192 \, d} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [A] time = 0.34, size = 109, normalized size = 0.96 \[ \frac {a^{2} \left (\left (\frac {\left (\sinh ^{3}\left (d x +c \right )\right )}{4}-\frac {3 \sinh \left (d x +c \right )}{8}\right ) \cosh \left (d x +c \right )+\frac {3 d x}{8}+\frac {3 c}{8}\right )+2 a b \left (\frac {\sinh ^{3}\left (d x +c \right )}{2 \cosh \left (d x +c \right )}-\frac {3 d x}{2}-\frac {3 c}{2}+\frac {3 \tanh \left (d x +c \right )}{2}\right )+b^{2} \left (d x +c -\tanh \left (d x +c \right )-\frac {\left (\tanh ^{3}\left (d x +c \right )\right )}{3}\right )}{d} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [B] time = 0.34, size = 211, normalized size = 1.85 \[ \frac {1}{64} \, a^{2} {\left (24 \, x + \frac {e^{\left (4 \, d x + 4 \, c\right )}}{d} - \frac {8 \, e^{\left (2 \, d x + 2 \, c\right )}}{d} + \frac {8 \, e^{\left (-2 \, d x - 2 \, c\right )}}{d} - \frac {e^{\left (-4 \, d x - 4 \, c\right )}}{d}\right )} + \frac {1}{3} \, b^{2} {\left (3 \, x + \frac {3 \, c}{d} - \frac {4 \, {\left (3 \, e^{\left (-2 \, d x - 2 \, c\right )} + 3 \, e^{\left (-4 \, d x - 4 \, c\right )} + 2\right )}}{d {\left (3 \, e^{\left (-2 \, d x - 2 \, c\right )} + 3 \, e^{\left (-4 \, d x - 4 \, c\right )} + e^{\left (-6 \, d x - 6 \, c\right )} + 1\right )}}\right )} - \frac {1}{4} \, a b {\left (\frac {12 \, {\left (d x + c\right )}}{d} + \frac {e^{\left (-2 \, d x - 2 \, c\right )}}{d} - \frac {17 \, e^{\left (-2 \, d x - 2 \, c\right )} + 1}{d {\left (e^{\left (-2 \, d x - 2 \, c\right )} + e^{\left (-4 \, d x - 4 \, c\right )}\right )}}\right )} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 0.27, size = 269, normalized size = 2.36 \[ x\,\left (\frac {3\,a^2}{8}-3\,a\,b+b^2\right )-\frac {\frac {4\,\left (a\,b-b^2\right )}{3\,d}+\frac {4\,{\mathrm {e}}^{4\,c+4\,d\,x}\,\left (a\,b-b^2\right )}{3\,d}+\frac {8\,a\,b\,{\mathrm {e}}^{2\,c+2\,d\,x}}{3\,d}}{3\,{\mathrm {e}}^{2\,c+2\,d\,x}+3\,{\mathrm {e}}^{4\,c+4\,d\,x}+{\mathrm {e}}^{6\,c+6\,d\,x}+1}-\frac {\frac {4\,{\mathrm {e}}^{2\,c+2\,d\,x}\,\left (a\,b-b^2\right )}{3\,d}+\frac {4\,a\,b}{3\,d}}{2\,{\mathrm {e}}^{2\,c+2\,d\,x}+{\mathrm {e}}^{4\,c+4\,d\,x}+1}-\frac {4\,\left (a\,b-b^2\right )}{3\,d\,\left ({\mathrm {e}}^{2\,c+2\,d\,x}+1\right )}+\frac {{\mathrm {e}}^{2\,c+2\,d\,x}\,\left (2\,a\,b-a^2\right )}{8\,d}-\frac {a^2\,{\mathrm {e}}^{-4\,c-4\,d\,x}}{64\,d}+\frac {a^2\,{\mathrm {e}}^{4\,c+4\,d\,x}}{64\,d}+\frac {a\,{\mathrm {e}}^{-2\,c-2\,d\,x}\,\left (a-2\,b\right )}{8\,d} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [F(-1)] time = 0.00, size = 0, normalized size = 0.00 \[ \text {Timed out} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________